package com.cct.digitalarchapi.dao;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.cct.digitalarchapi.pojo.ArchDept;
import com.cct.digitalarchapi.pojo.vo.ArchDeptVo;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import java.util.List;


@Repository
public interface ArchDeptMapper  extends BaseMapper<ArchDept> {
    IPage<ArchDeptVo> getAllArchDept(IPage<ArchDeptVo> page);

    void addArchDept(ArchDept archDept);

    ArchDept selectLastArchDept();

    void deleteArchDept(@Param("archDeptId") int archDeptId);

    void updateArchDept(ArchDept archDept);

    int queryHaveSameName(@Param("archDeptName") String archDeptName);

    void updateManager(@Param("archDeptId") int archDeptId,@Param("manager") String manager);

    List<ArchDept> getAllDept();

    ArchDept getArchDeptById(@Param("archDeptId") int archDeptId);


}
